﻿using BCEntity.OA.BusinessFlowCategory;
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;

namespace BCData.OA.BusinessFlowCategory
{
    /// <summary>
    /// OA系统业务流分类
    /// </summary>
	public interface IBusinessFlowCategoryData
    {
        #region  成员方法
        /// <summary>
        /// 是否存在该记录
        /// </summary>
        /// <param name="businessFlowCategoryId">OA系统业务流分类Id</param>
        Task<bool> Exists(long businessFlowCategoryId);
        /// <summary>
        /// 是否存在该记录
        /// </summary>
        /// <param name="businessFlowCategoryName">OA系统业务流分类名称</param>
        Task<bool> Exists(string businessFlowCategoryName);
        /// <summary>
        /// 增加OA系统业务流分类
        /// </summary>
        /// <param name="entity">OA系统业务流分类信息</param>
        Task<BusinessFlowCategoryEntity> Add(BusinessFlowCategoryEntity entity);
        /// <summary>
        /// 更新OA系统业务流分类
        /// </summary>
        /// <param name="entity">OA系统业务流分类信息</param>
        Task<BusinessFlowCategoryEntity> Update(BusinessFlowCategoryEntity entity);
        /// <summary>
        /// 删除OA系统业务流分类
        /// </summary>
        /// <param name="businessFlowCategoryId">OA系统业务流分类Id</param>
        Task<bool> Delete(long businessFlowCategoryId);
        /// <summary>
        /// 获取OA系统业务流分类
        /// </summary>
        /// <param name="businessFlowCategoryId">OA系统业务流分类Id</param>
        Task<BusinessFlowCategoryEntity> GetEntity(long businessFlowCategoryId);
        /// <summary>
        /// 获取OA系统业务流分类列表
        /// </summary>
        /// <param name="companyId">公司Id</param>
        Task<IEnumerable<BusinessFlowCategoryEntity>> GetList(int companyId);
        /// <summary>
        /// 获取OA系统业务流分类分页列表
        /// </summary>
        /// <param name="companyId">公司Id</param>
        /// <param name="businessFlowCategoryName">OA系统业务流分类名称</param>
        /// <param name="start">开始时间</param>
        /// <param name="end">结束时间</param>
        /// <param name="pageIndex">当前页码</param>
        /// <param name="pageSize">OA系统业务流分类每页数据条数</param>
        Task<(IEnumerable<BusinessFlowCategoryEntity>, int)> Query(int companyId, string businessFlowCategoryName, DateTime? start, DateTime? end, int pageIndex, int pageSize);
        #endregion  成员方法
    }
}
